<?php defined('BASEPATH') OR exit('No direct script access allowed');

if ( ! function_exists('delete_cache') ) {
	function delete_cache( $pages ) {
		$ci = & get_instance();
		$ci->load->driver('cache');
		foreach($pages as $p){
			$file = md5($p);
			//$ci->cache->delete($file);
			$CI =& get_instance();
			$path = $CI->config->item('cache_path');
			if(is_file($path.$file)){
				unlink($path.$file);
			}
			
		}
		
	}
}
